/* 
 * File:   SharedMemory.h
 * Author: huzeyfe
 *
 * Created on 8. Dezember 2011, 07:23
 */

#ifndef _SHAREDMEMORY_H
#define	_SHAREDMEMORY_H

#include <stdio.h>
#include <iostream>

class SharedMemory {
public:
    SharedMemory(int);
    ~SharedMemory();
    void enter(int);
    int leave();
    bool isEmpty();
    bool overflow;
protected:
    int * array;
    int buffer, l, u;
    int counter;
};

#endif	/* _SHAREDMEMORY_H */

